﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="List.ascx.cs" Inherits="Function_List" %>
<div class="subnav admin-views-subnav">
    <div class="container-fluid">
        <ul class="nav nav-pills">
            <li class="active"><a href="#">Function</a></li>
            <li><a href="Default.aspx?controller=create">Thêm mới</a></li>
        </ul>
    </div>
</div>
<div class="container-fluid">
    <div class="page-header clearfix">
        <h2 class="page-title pull-left">Danh sách Function
           
            <span class="loaded" id="Loader"><i class="fa fa-spinner fa-spin fa-sm"></i></span>
        </h2>
        <a type="button" class="btn btn-success btn-header pull-right" href="Default.aspx?controller=create"><i class="fa fa-plus"></i>Thêm mới</a>
    </div>


    <div class="toolbar-grid clearfix">
        <div class="pull-left">
            <button onclick="return $.ColorLife.jsonDeleteSelectedData('Function')" class="btn btn-danger btn-sm delete-selected" id="deleteSelected"><i class="fa fa-times"></i>Xóa đã chọn</button>

            <a onclick="return $.ColorLife.jsonDeleteAllData('Function')" style="display: none" class="btn btn-link" href="javascript:void(0)">Xóa tất cả</a>

        </div>
        <div class="pull-right filterbar clearfix">
                    <div>


                        <div class="btn-group">
                            <span class="lbl-show">Hiển thị:</span>
                            <select onchange="return doSubmit('#form0')" style="float: none" class="btn btn-default btn-sm" id="pagesize" size="1" name="pagesize">
                                <option selected="selected" value="10">10</option>
                                <option value="25">25</option>
                                <option value="50">50</option>
                                <option value="100">100</option>
                            </select>

                            <span class="lbl-show">WORKGROUP:</span>

                            <asp:DropDownList ID="WorkGroupID" runat="server" CssClass="btn btn-default btn-sm" AppendDataBoundItems="true" AutoPostBack="true" OnSelectedIndexChanged="WorkGroupID_SelectedIndexChanged" Style="float: none; text-align: left">
                                <asp:ListItem Value="-1">-- Workgroup --</asp:ListItem>
                            </asp:DropDownList>
                        </div>


                        <div class="pull-right btn-flt-r">

                            <asp:ColorLifeButtonEx ID="btnTimKiem" runat="server" Text="Tìm kiếm" ValidationGroup="timVal" IconClass="fa fa-search" CssClass="btn btn-primary btn-sm" OnClick="btnTimKiem_Click" ToolTip="Tìm" />
                        </div>
                        <div class="pull-right search-grid">
                            <asp:ColorLifeTextBoxEx ID="TuKhoa" runat="server" IsVal="false" ValidationGroup="timVal" CustomeCssClass="input-sm form-control pull-right" Placeholder="Nhập từ khóa cần tìm:" ToolTip="Nhập từ khóa cần tìm: Họ tên, Email, Số điện thoại, Lớp.." />
                        </div>
                    </div>
                </div>
    </div>
    <div id="dvAjaxData">


        <table id="Function" class="table table-hover table-nomargin dataTable table-bordered">
            <thead>
                <tr class='thefilter'>
                    <th>
                        <input type="checkbox" name="check_all" id="check_all" title="Chọn / Bỏ chọn" rel="tooltip">
                    </th>
                    <th class="table-item-title">FunctionID</th>
                    <th class="table-item-title">WorkGroupID</th>
                    <th class="table-item-title">Name</th>
                    <th class="table-item-title">Image</th>
                    <th class="table-item-title">Url</th>

                    <th width="100px"><i class="fa fa-cogs"></i>Công cụ</th>
                </tr>
            </thead>
            <tbody>
                <asp:Repeater ID="rptItems" runat="server">
                    <ItemTemplate>
                        <tr id="<%# Eval("FunctionID") %>" data-ispublish="<%# Eval("FunctionID") %>">
                            <td class="with-checkbox">
                                <input type="checkbox" name="check" class="check" value="<%# Eval("FunctionID") %>">
                            </td>
                            <td class="table-item-title"><%#Eval("FunctionID") %></td>
                            <td class="table-item-title"><%#Eval("WorkGroup.Name") %></td>
                            <td class="table-item-title"><%#Eval("Name") %></td>
                            <td class="table-item-title"><%#Eval("Image") %></td>
                            <td class="table-item-title"><%#Eval("Url") %></td>

                            <td class="td-actions ">
                                <div class="hidden-phone visible-desktop action-buttons">
                                    <a href="#" class="blue">
                                        <i class="fa fa-eye"></i>
                                    </a>
                                    <a href="Default.aspx?controller=edit&id=<%#Eval("FunctionID") %>" class="green" rel="tooltip" title="Sửa">
                                        <i class="fa fa-edit"></i>
                                    </a>
                                    <a class="red" rel="tooltip" title="Xóa" href="Default.aspx?controller=delete&id=<%#Eval("FunctionID") %>" onclick=".return $.ColorLife.jsonDeleteData(this)">
                                        <i class="fa fa-trash-o"></i>
                                    </a>
                                </div>
                            </td>
                        </tr>
                    </ItemTemplate>
                </asp:Repeater>

            </tbody>
        </table>


        <asp:PagingControl ID="PagingControl1" runat="server" FirstPageText="|<" PreviousPageText="<<" NextPageText=">>" LastPageText=">|" />
    </div>
</div>


